package com.meituan.sdk.model.ddzhkh.miniprogram.tradeQueryPayToken;

import com.meituan.sdk.annotations.ApiMeta;
import com.google.gson.reflect.TypeToken;
import javax.validation.constraints.NotBlank;
import java.lang.reflect.Type;
import com.meituan.sdk.internal.utils.JsonUtil;
import com.google.gson.annotations.SerializedName;
import javax.validation.constraints.NotNull;
import com.meituan.sdk.MeituanResponse;
import com.meituan.sdk.MeituanRequest;

/**
* 查询支付token
* This file was automatically generated.
*/
@ApiMeta(
    path = "/ddzhkh/miniprogram/trade/query_pay_token",
    businessId = 59,
    apiVersion = "10000",
    apiName = "trade_query_pay_token",
    needAuth = true
)
public class TradeQueryPayTokenRequest implements MeituanRequest<TradeQueryPayTokenResponse> {
    @NotBlank(message = "generalBizData不能为空")
    @SerializedName("generalBizData")
    private String generalBizData;
    /**
    * <p data-diff-id="ct-diff-id-ea7b65a4-0f83-421f-8189-d3edd4743332">查询token请求参数</p>
    */
    @NotNull(message = "queryPayTokenReq不能为空")
    @SerializedName("queryPayTokenReq")
    private RefundOrderReq queryPayTokenReq;

    public String getGeneralBizData() {
        return generalBizData;
    }
    public void setGeneralBizData(String generalBizData) {
        this.generalBizData = generalBizData;
    }
    public RefundOrderReq getQueryPayTokenReq() {
        return queryPayTokenReq;
    }
    public void setQueryPayTokenReq(RefundOrderReq queryPayTokenReq) {
        this.queryPayTokenReq = queryPayTokenReq;
    }


    @Override
    public MeituanResponse<TradeQueryPayTokenResponse> deserializeResponse(String response) {
        Type type = new TypeToken<MeituanResponse<TradeQueryPayTokenResponse>>(){}.getType();
        return JsonUtil.fromJson(response, type);
    }
    @Override
    public String serializeToJson() {
        return JsonUtil.toJson(this);
    }


    @Override
    public String toString() {
        return "TradeQueryPayTokenRequest{" + "generalBizData=" + generalBizData + "," + "queryPayTokenReq=" + queryPayTokenReq + "}";
    }
}
